from flask import Flask
from settings import Config, db
from index_page import index_page
from list_page import list_page
from detail_page import detail_page
from user import user_page
from get_jingwei import jingwei_page  # 导入新的蓝图
git 
app = Flask(__name__)#创建了一个 Flask 应用实例
#将应用程序配置从一个配置对象中加载。Config 是从 settings 模块导入的配置类。
app.config.from_object(Config)
db.init_app(app)

# 将蓝图注册到app中
app.register_blueprint(index_page, url_prefix='/')
app.register_blueprint(list_page, url_prefix='/')
app.register_blueprint(detail_page, url_prefix='/')
app.register_blueprint(user_page, url_prefix='/')
app.register_blueprint(jingwei_page, url_prefix='/')  # 注册新的蓝图

if __name__ == '__main__':
    app.run(debug=True)
